#include "Vector2D.h"
using namespace ms;

Vector2D::Vector2D() {
	x = 0;
	y = 0;
}

Vector2D::Vector2D(real x_, real y_) {
	x = x_;
	y = y_;
}

void Vector2D::set(Vector2D * v) {
	x = v -> x;
	y = v -> y;
}
void Vector2D::set(real x_, real y_) {
	x = x_;
	y = y_;
}

void Vector2D::add(real x_, real y_) {
	x += x_;
	y += y_;
}

void Vector2D::add(Vector2D * v) {
	x += v -> x;
	y += v -> y;
}

void Vector2D::mult(real n) {
	x *= n;
	y *= n;
}

void Vector2D::div(real n) {
	x /= n;
	y /= n;
}
